package com.waves.design.factory;

/**
 * 通过向上造型获取即可
 */
public class FactoryTest {

    public static void main(String[] args) {

        CoffeeFactory coffeeFactory = new UsaCoffeeFactory();
        coffeeFactory.createCoffee();
        CoffeeFactory latteCoffeeFactory = new LatteCoffeeFactory();
        latteCoffeeFactory.createCoffee();
    }
}
